//
//  OrdersTableViewCell.m
//  ZiJinLian
//
//  Created by 🐛 on 2017/3/28.
//  Copyright © 2017年 lzy. All rights reserved.
//

#import "OrdersTableViewCell.h"

@implementation OrdersTableViewCell

- (void)awakeFromNib {
    [super awakeFromNib];
    self.selectionStyle=UITableViewCellSelectionStyleNone;
    // Initialization code
}
-(void)setModel:(UserOrderModle *)model{
    _model=model;
    [self creatShopImag];
}
-(void)creatShopImag{
    for (UIView *view in self.contentView.subviews) {
        [view removeFromSuperview];
    }
    for (int i=0; i<self.model.items.count; i++) {
        NSDictionary*dic=self.model.items[i];
        self.shopImag=[[UIImageView alloc]initWithFrame:CGRectMake(10+60*i, 10, 50, 50)];
        [self.shopImag sd_setImageWithURL:[NSURL URLWithString:dic[@"imageUrl"]] placeholderImage:[UIImage imageNamed:@"placeholderImage"]];
        [self.contentView addSubview:self.shopImag];
    }
    
}
- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

@end
